

; Global Defines
; accesible to anyone who wants them
; some of the defines in this file would have been a static members if scheme had them

(load "optimization.scm")


; general info
(define *app-name* "Schiero")
(define *debug* #f)
(define *fps* #i30)
(define *help-text* (vector "Schiero - By Viktor Klasson & Robert Cranston" 
                            ""
                            "Controls:"
                            " - Walk around with left/right"
                            " - Aim with up/down"
                            " - Jump with the jump key, shoot with the shoot key"
                            " - To change weapon, press and hold change and then press left/right"
                            " - To use the hook, press and hold change and press shoot, "
                            "   release the hook by pressing jump"
                            " - To dig, move in the direction you want to dig and press the"
                            "   opposite direction, only diggable materials can be digged through"))


; gameplay
(define *health-time* 30) ; new random health roughly every 30 seconds
(define *health-default* 30)

; math
(define *radians-per-degree* (fl/ pi #i180))


; internals
(define *user-interface* #f)
(define *world* #f)
(define *spf* (fl/ #i1 *fps*))
(define *debug-pos* #i0)


; global timing
(define *time-updated* #f)
(define *time-delta*   #i0)


; Physics constants
(define *gravity*  #i150)
(define *bounce-dampening* #i1/2)


; player controls
(define *player1-controls* (vector 'left 'right 'up 'down #\- #\. #\,))
(define *player2-controls* (vector #\f   #\h    #\t #\g   #\x #\z #\<))
(define *player-control-left*   0)
(define *player-control-right*  1)
(define *player-control-up*     2)
(define *player-control-down*   3)
(define *player-control-shoot*  4)
(define *player-control-jump*   5)
(define *player-control-change* 6)
(define *num-player-controls*   (add1 *player-control-change*))
(define *player-aim-speed* #i120)
(define *player-aim-min* #i-90)
(define *player-aim-max* #i90)
; player movement constants
(define *player-walk-acceleration*  #i300)
(define *player-fly-acceleration*   #i100)
(define *player-jump-speed*         #i120)
(define *player-feet-height* 5)
(define *hook-acceleration* #i500)
; player characteristics
(define *player-start-lives* 3)
(define *player-max-health* 100)
(define *num-player-weapons* 3)
(define *player-stats-pos* 0)
(define *num-players-left* #f)

; file name standards
(define *resource-file-extension*   ".png")
(define *graphics-folder*           "graphics/")
(define *maps-folder*               "maps/")
(define *maps-collision-extension*  "_collision")
(define *maps-background-extension* "_background")


; graphics
(define *graphics* '())                    ; name->vector-of-bitmaps association list
(define *num-degree-bitmaps* (fl/ 360 45)) ; how many bitmaps per whole turn?


; collision data loading
(define *collision-limit-solid*       50)
(define *collision-limit-destroyable* 200)


